package com.lzz.oss.adapter;

import com.lzz.oss.entity.FileInfo;
import com.lzz.oss.util.MinioUtil;
import lombok.SneakyThrows;
import org.springframework.web.multipart.MultipartFile;

import javax.annotation.Resource;
import java.io.InputStream;
import java.util.ArrayList;
import java.util.List;

/**
 * @description:
 * @author: 23622
 * @time: 2024/5/29 16:19
 */
public class AliStorageAdapter implements StorageAdapter {

    @Resource
    private MinioUtil minioUtil;

    @Override
    @SneakyThrows
    public void createBucket(String bucket) {

    }

    @Override
    @SneakyThrows
    public void uploadFile(MultipartFile uploadFile, String bucket, String objectName) {

    }

    @Override
    @SneakyThrows
    public List<String> getAllBucket() {
        List<String> bucketName = new ArrayList<>();
        bucketName.add("aliyun");
        return bucketName;
    }

    @Override
    @SneakyThrows
    public List<FileInfo> getAllFile(String bucket) {
        return null;
    }

    @Override
    @SneakyThrows
    public InputStream downLoad(String bucket, String objectName) {
        return null;
    }

    @Override
    @SneakyThrows
    public void deleteBucket(String bucket) {

    }

    @Override
    @SneakyThrows
    public void deleteObject(String bucket, String objectName) {

    }
}
